package tianxing

import (
	"encoding/json"
	ms "gin_template/core/request"

	"go.uber.org/zap"
)

func RequestDairy(config interface{}) string {
	conf := config.(*Config)
	result := &Result{}
	res := ms.RequestGet(conf.Url + "/tiangou/index?key=" + conf.Key)
	err := json.Unmarshal(res, &result)
	if err != nil {
		zap.L().Info("RequestSayDairy序列化失败", zap.Error(err))
	}
	var info = result.Newslist[0].Content
	return info

}
